package com.lixingqu.mvpdemo;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;

import com.lixingqu.mvpdemo.ui.download.DownloadActivity;
import com.lixingqu.mvpdemo.ui.itemdrag.DragActivity;
import com.lixingqu.mvpdemo.ui.login.LoginActivity;
import com.lixingqu.mvpdemo.ui.news.NewsActivity;

import butterknife.ButterKnife;
import butterknife.OnClick;

public class MainActivity extends Activity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        ButterKnife.bind(this);
    }

    @OnClick({R.id.btn_tologin, R.id.btn_news, R.id.btn_todownload,R.id.btn_toDrag})
    public void onClick(View view) {
        switch (view.getId()) {
            case R.id.btn_tologin:
                startActivity(new Intent(MainActivity.this, LoginActivity.class));
                break;
            case R.id.btn_news:
                startActivity(new Intent(MainActivity.this, NewsActivity.class));
                break;
            case R.id.btn_todownload:
                startActivity(new Intent(MainActivity.this, DownloadActivity.class));
                break;
            case R.id.btn_toDrag:
                startActivity(new Intent(MainActivity.this, DragActivity.class));
                break;
            default:
                break;
        }
    }

}
